package org.anjan.dp.observer;

/**
 * Created by chebbaso on 12/4/14.
 */
public class Main {
    public static void main(String[] args) {
        StockGrabber grabber1 = new StockGrabber();
        Observer applObserver = new APPLObserver();
        Observer googObserver = new GOOGObserver();
        Observer genericObserver = new GenericObserver();

        grabber1.register(applObserver);
        grabber1.register(googObserver);
        grabber1.register(genericObserver);

        grabber1.setPrice("GOOG", 123);
        grabber1.setPrice("GOOG", 125);
        grabber1.setPrice("APPL", 125);
        grabber1.setPrice("CSCO", 125);

    }
}
